package com.zhijian.medical.dao.local;

import com.zhijian.medical.entity.po.EmployeePhysicalRecord;
import com.zhijian.medical.entity.vo.request.EmployeePhysicalRecordSearchVo;
import com.zhijian.medical.entity.vo.response.EmployeePhysicalRecordVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface EmployeePhysicalRecordMapper {
    int deleteByPrimaryKey(Long id);

    int insert(EmployeePhysicalRecord record);

    int insertSelective(EmployeePhysicalRecord record);

    EmployeePhysicalRecord selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(EmployeePhysicalRecord record);

    int updateByPrimaryKey(EmployeePhysicalRecord record);

    /**
     * 查询总数
     *
     * @param employeePhysicalRecordSearchVo
     * @return
     */
    int count(EmployeePhysicalRecordSearchVo employeePhysicalRecordSearchVo);

    /**
     * 查询列表
     *
     * @param employeePhysicalRecordSearchVo
     * @return
     */
    List<EmployeePhysicalRecordVo> selectList(EmployeePhysicalRecordSearchVo employeePhysicalRecordSearchVo);

    /**
     * 查询单个
     *
     * @param employeePhysicalRecordSearchVo
     * @return
     */
    EmployeePhysicalRecordVo selectOne(EmployeePhysicalRecordSearchVo employeePhysicalRecordSearchVo);

    /**
     * 根据ID查询vo
     *
     * @param id
     * @return
     */
    EmployeePhysicalRecordVo selectVoById(Long id);

    /**
     * 批量删除
     *
     * @param idList
     * @return
     */
    void deleteByIdList(@Param("idList") List<Long> idList);

    /**
     * 动态删除
     *
     * @param employeePhysicalRecordSearchVo
     * @return
     */
    void deleteByCondition(EmployeePhysicalRecordSearchVo employeePhysicalRecordSearchVo);

    /**
     * 批量新增
     *
     * @param entities
     * @return
     */
    int insertBatch(@Param("entities") List<EmployeePhysicalRecord> entities);

    /**
     * 根据PersonId查询列表
     *
     * @param personId
     * @return
     */
    List<EmployeePhysicalRecordVo> selectListByPersonId(Long personId);
}